package com.quan.admin.service;

import com.quan.admin.entity.SysPermission;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.quan.commons.core.utils.PageUtils;
import com.quan.commons.core.biz.support.MyBaseService;

import java.io.Serializable;
import java.util.List;


/**
 * 系统-菜单权限
 *
 * @author yhaoquan
 * @email yhaoquan@163.com
 * @date 2020-08-03 20:32:03
 */
public interface SysPermissionService extends MyBaseService<SysPermission> {

    /**
     * 分页查询列表
     * @param entity
     * @param pageUtils
     * @return
     */
    public IPage<SysPermission> selectMyPage(PageUtils pageUtils, SysPermission entity);

    /**
     * 根据菜单ID加载对应权限
     * @param menuId
     * @return
     */
    List<SysPermission> findPermissionByMenuId(Serializable menuId);

    /**
     * 根据菜单ID删除菜单权限
     * @param menuId
     * @return
     */
    public boolean deleteByMenuId(Serializable menuId);
}

